/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package controller;

import com.opensymphony.xwork2.ActionContext;
import javax.servlet.RequestDispatcher;
import models.PageBO;
import org.apache.struts2.ServletActionContext;

/**
 *
 * @author Liem
 */

public class ReactivePageAction {
    private String pageId;

    public ReactivePageAction() {
    }

    public String execute() throws Exception {
        try {
            int id = Integer.parseInt(pageId);
            PageBO.setPageStatus(id, true);
        } catch (Exception e) {
            return "fail";
        }
        return "success";
    }

    public String getPageId() {
        return pageId;
    }

    public void setPageId(String pageId) {
        this.pageId = pageId;
    }

    

}